package com.example.springboot.utils;


import com.example.springboot.domain.Girl;
import com.example.springboot.domain.Result;

public class ResultUtil {

    public static Result success(Object Object){
        Result result = new Result();
        result.setCode(0);
        result.setMsg("成功");
        result.setData(Object);
        return result;
    }

    public static void success(){
        success(null);
    }

    public static Result error(Integer code,String errorMsg){
        Result result = new Result();
        result.setCode(code);
        result.setMsg(errorMsg);
        return result;
    }

}
